package com.sqlquery.demo.service;
import com.sqlquery.demo.entity.*;
import java.util.*;
public interface UserService {
    List<Map<String, Object>> findByName(String name);
    User findById(Integer id);
    //根据用户名查找用户所有的角色
    List<Map<String, Object>> findRoleByUserName(String name);
    //根据角色名查找所有的用户
    List<Map<String, Object>> findUserByRoleName(String name);
    //根据id删除
    int deleteId(Integer id);
    int addUser(User user);
    int addRoleById(User_Role user_role);
    int delRoleById(User_Role user_role);
    int updateUser(User user);
    List<Map<String, Object>> findRoleByUserId(Integer id);
    List<Map<String, Object>> findUserByRoleId(Integer id);
    //查询所有
    List<Map<String, Object>> findAll(Integer page);
}